package com.hitqz.robot.biz.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.hitqz.robot.api.business.dto.RobotCommonPathDto;
import com.hitqz.robot.api.business.entity.RobotLockPathEntity;

import java.util.List;


/**
 * <p>
 * 机器人管理 服务类
 * </p>
 *
 * @author xiaojiezhang
 * @since 2021-12-20
 */
public interface RobotLockPathService extends IService<RobotLockPathEntity> {

    /**
     *
     * @param robotSn
     * @return
     */
    List<RobotLockPathEntity> getByRobotSn(String robotSn);
    /**
     * 批量保存
     * @param
     * @return
     */
    Integer insert(String robotSn, RobotCommonPathDto commonPathDto, Boolean deleteFlag);

    /**
     * 根据名称获取锁
     * @param lockName
     * @return
     */
    RobotLockPathEntity getByLockName(String lockName);

    /**
     *
     * @param commonPath
     * @return
     */
    int deleteByCommonPath(String commonPath);

    /**
     *
     * @param robotSn
     * @return
     */
    int deleteByRobotSn(String robotSn);

    int  deleteByRobotSnAndCommpathName(String robotSn,String commonPath);

    /**
     * 删除不存在公共路径的资源
     * @param commonPathNameF
     * @param commonPathNameS
     * @param commonPathNameT
     * @return
     */
    int  deleteNotExist(String commonPathNameF,String commonPathNameS,String commonPathNameT);
}
